import request from "@/utils/request";

export function getInspectionIqcByPage(query) {
  return request({
    url: `/system/inspectionIqc/getInspectionIqcByPage`,
    method: "post",
    data: query,
  });
}

// 增加流程模型

export function addInspectionIqc(query) {
  return request({
    url: `/system/inspectionIqc/addInspectionIqc`,
    method: "post",
    data: query,
  });
}
/**
 *
 * @param {*} query
 * @returns
 */
export function delInspectionIqc(query) {
  return request({
    url: `/system/inspectionIqc/delInspectionIqc`,
    method: "post",
    data: query,
  });
}

export function updateInspectionIqc(query) {
  return request({
    url: `/system/inspectionIqc/updateInspectionIqc`,
    method: "post",
    data: query,
  });
}

/**
 * 添加
 * @param {*} query
 * @returns
 */

export function uploadInspectionIqc(params) {
  return request("/system/inspectionIqc/uploadInspectionIqc", {
    method: "POST",
    data: params,
    headers: { "Content-Type": "application/x-www-form-urlencoded" },
  });
}

export async function exportInspectionIqc(params) {
  return request("/system/inspectionIqc/exportInspectionIqc", {
    method: "POST",
    data: params,
    responseType: "blob",
  });
}
